﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using CommonWFLibrary;
using System.IO;
using System.Configuration;

namespace DeepTalkRenderService.Services
{
    /// <summary>
    /// A basic persistance service to be used by the workflow. Saves to a local directory.
    /// </summary>
    public class DTRPersistance : FilePersistenceService
	{
        private static DirectoryInfo GetDirToSave()
        {
            string pdir = ConfigurationManager.AppSettings["PersitanceDirectory"];
            return new DirectoryInfo(pdir);
        }

        /// <summary>
        /// Basically create ourselves with the correct information.
        /// </summary>
        public DTRPersistance()
            : base (true, GetDirToSave())
        {
        }
	}
}
